import request from '@/config/axios'

// 微博用户基本信息 VO
export interface WeiboUserscountsVO {
  id: number // 主键
  weiboId: number // 微博ID
  followersCount: number // 粉丝数
  friendsCount: number // 关注数
  statusesCount: number // 微博数
  privateFriendsCount: number // private关注数
  pagefriendsCount: number // page关注数
  syncDate: Date // 同步时间
}

// 微博用户基本信息 API
export const WeiboUserscountsApi = {
  // 查询微博用户基本信息分页
  getWeiboUserscountsPage: async (params: any) => {
    return await request.get({ url: `/integration/weibo-userscounts/page`, params })
  },

  // 查询微博用户基本信息详情
  getWeiboUserscounts: async (id: number) => {
    return await request.get({ url: `/integration/weibo-userscounts/get?id=` + id })
  },

  // 新增微博用户基本信息
  createWeiboUserscounts: async (data: WeiboUserscountsVO) => {
    return await request.post({ url: `/integration/weibo-userscounts/create`, data })
  },

  // 修改微博用户基本信息
  updateWeiboUserscounts: async (data: WeiboUserscountsVO) => {
    return await request.post({ url: `/integration/weibo-userscounts/update`, data })
  },

  // 删除微博用户基本信息
  deleteWeiboUserscounts: async (id: number) => {
    return await request.get({ url: `/integration/weibo-userscounts/delete?id=` + id })
  },

  // 导出微博用户基本信息 Excel
  exportWeiboUserscounts: async (params) => {
    return await request.download({ url: `/integration/weibo-userscounts/export-excel`, params })
  }
}